﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Menu.aspx.cs" Inherits="Menu_Menu" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Untitled Page</title>
    <link href="../Styles/accounts.css" rel="stylesheet" type="text/css" />    
    <link href="js/sdmenu.css" rel="stylesheet" type="text/css" />
    <link href="js/anylinkmenu.css" rel="stylesheet" type="text/css" />
    <style>
	    body
	    {
	        scrollbar-3dlight-color:#dddddd; 
            scrollbar-arrow-color:#88bf64; 
            scrollbar-base-color:#ff6347; 
            scrollbar-darkshadow-color:#dddddd; 
            scrollbar-face-color:#647e59; 
            scrollbar-highlight-color:#ff69b4; 
            scrollbar-shadow-color:#f0f;
            scrollbar-track-color:#505050; 
	    }
	</style>
</head>

 <body style=" background-color:#505050; background-image:url('../Images/b1.jpg'); background-repeat:repeat-x; width:100%; margin:0px; padding:0;">  
   <form id="form1" runat="server">
    <div style="padding-top:40px; padding-left:10px;">
        <div style="border:1px solid #9e9e9e;">
         <div id="my_menu" class="sdmenu" >
             <asp:Repeater id="ParentRepeater" runat="server" OnItemDataBound="ParentRepeater_ItemDataBound">            
            <ItemTemplate>
              <div class="collapsed">
              <span>
                <%# Eval("text")%>
               </span>
                 <%-- adding one more repeater within this item template --%>
                <asp:Repeater id="ChildRepeater" runat="server"> 
                 <ItemTemplate>
                     <asp:HyperLink CssClass="menuanchorclass" ID="hy1" runat="server" Text='<%# Eval("text")%>' NavigateUrl="" Target="contentframe"></asp:HyperLink>
                        <script language="javascript" type="text/javascript">
                            var anylinkmenu<%=++j%> = { divclass: 'anylinkmenu', inlinestyle: 'width:120px; background:#636363; margin-top:-10px;', linktarget: 'contentframe'} //Second menu variable. Same precaution.
                            anylinkmenu<%=j%>.items = [
	                                ["Add New", '<%#ResolveUrl(Eval("urladdnew").ToString())%>'],
	                                ["View", '<%#ResolveUrl(Eval("urlView").ToString())%>']
                                ];

                        </script>
                </ItemTemplate>
                </asp:Repeater>
                </div>
                </ItemTemplate>
                </asp:Repeater>      
         </div>                  
         </div>
       </div>
     <script src="js/sdmenu.js" type="text/javascript"></script>
      <script src="js/anylinkmenu.js" type="text/javascript"></script>
      <script src="js/menucontents.js" type="text/javascript"></script>
      <script type="text/javascript">
          // <![CDATA[
          var myMenu;
          function initsdmenu() {
              myMenu = new SDMenu("my_menu");
              myMenu.init();
              myMenu.oneSmOnly = true;
              //myMenu.collapseAll();
          };
          function loadfunc() {
              try {
                  initsdmenu();
              }
              catch (Error) {
              }
          }
          window.onload = loadfunc;
          // ]]>
          anylinkmenu.init("menuanchorclass");
	</script>	
   </form>
</body>
</html>
